//输入组件
export const INPUT_COMPONENTS = [
  {
    tag: 'a-input',
    conf: {
      tagName: '文本',
      autoFocus: true,
      placeholder: '请输入',
      disabled: false,
      maxLength: 6,
      allowClear: true,
      width: 24,
    },
    events: {
      blur: null,
      change: null,
      clear: null,
      focus: null,
      input: null,
    },
    slots: {
      append: null,
      prefix: null,
      prepend: null,
      suffix: null,
    },
  },
  {
    tag: 'a-input-number',
    conf: { tagName: '数字', width: 24 },
  },
  {
    tag: 'a-radio-group',
    conf: {
      tagName: '单选框',
      width: 24,
      children: [
        {
          label: '男性',
          value: 'male',
        },
        {
          label: '女性',
          value: 'female',
        },
        {
          label: '其他',
          value: 'other',
        },
      ],
    },
  },
  {
    tag: 'a-rate',
    conf: { tagName: '评分', width: 24 },
  },
  {
    tag: 'a-select',
    conf: {
      tagName: '下拉选择',
      width: 24,
      children: [
        {
          label: '男性',
          value: 'male',
        },
        {
          label: '女性',
          value: 'female',
        },
        {
          label: '其他',
          value: 'other',
        },
      ],
    },
  },
  {
    tag: 'a-switch',
    conf: { tagName: '开关', width: 24 },
  },
  {
    tag: 'a-time-picker',
    conf: { tagName: '时间选择', width: 24 },
  },
  {
    tag: 'a-tree-select',
    conf: {
      tagName: '树型选择',
      width: 24,
      placeholder: '请选择',
      treeData: [
        {
          title: 'Node1',
          value: '0-0',
          key: '0-0',
          children: [
            {
              title: 'Child Node1',
              value: '0-0-1',
              key: '0-0-1',
            },
            {
              title: 'Child Node2',
              value: '0-0-2',
              key: '0-0-2',
            },
          ],
        },
        {
          title: 'Node2',
          value: '0-1',
          key: '0-1',
        },
      ],
    },
  },
  {
    tag: 'a-upload',
    conf: { tagName: '文件上传', width: 24 },
  },
  {
    tag: 'a-cascader',
    conf: {
      tagName: '级联选择',
      width: 24,
      options: [
        {
          value: 'zhejiang',
          label: 'Zhejiang',
          children: [
            {
              value: 'hangzhou',
              label: 'Hangzhou',
              children: [
                {
                  value: 'xihu',
                  label: 'West Lake',
                },
              ],
            },
          ],
        },
        {
          value: 'jiangsu',
          label: 'Jiangsu',
          children: [
            {
              value: 'nanjing',
              label: 'Nanjing',
              children: [
                {
                  value: 'zhonghuamen',
                  label: 'Zhong Hua Men',
                },
              ],
            },
          ],
        },
      ],
    },
  },
  {
    tag: 'a-checkbox-group',
    conf: {
      tagName: '多选框',
      width: 24,
      options: ['Apple', 'Pear', 'Orange'],
    },
  },
  {
    tag: 'a-date-picker',
    conf: { tagName: '日期选择', width: 24 },
  },

  {
    tag: 'a-collapse',
    children: [],
    conf: { tagName: '折叠面板', width: 24, header: '面板内容' },
  },
  {
    tag: 'a-tabs',
    children: [],
    layouts: [
      {
        name: 'tab -1',
      },
    ],
    conf: { tagName: 'Tabs页', width: 24 },
  },
];

//布局组件
export const LAYOUT_COMPONENTS = [
  {
    tag: 'a-collapse',
    children: [],
    conf: { tagName: '折叠面板', width: 24 },
  },
  {
    tag: 'a-tabs',
    children: [],
    conf: { tagName: 'Tabs页', width: 24 },
  },
];
